Ext.define('Sencha.view.CollectorFormView', {
    extend: 'Ext.Container',
    xtype: 'collectorformview',
           
    config: {
        title: 'Collector',
        styleHtmlContent: true,
        scrollable: 'vertical'
    },   
	
    initialize: function () {
    	this.callParent(arguments);        
        
        var fieldSet = {
	        xtype: 'fieldset',
	        id: 'collectorNameFieldset',
	        items: [
	            {
	                xtype: 'textfield',
	                name : 'collectorName',
	                label: 'Name',
                    id: 'collectorNameField'
	            },
	            {
	                xtype: 'datepickerfield',
	                picker:{yearFrom: 1900},
	                name : 'collectorDOB',
	                label: 'Date of Birth',
                    id: 'collectorDOBField'
	            }
	        ]
           };
           
           
	   	var genderFieldSet = {
	   		 xtype: 'fieldset',
	   		 id: 'collectorGenderFieldset',
	   		 title: 'Gender',
	   		 items: [
	   		 
	   		 	{
	   		 	    xtype: 'radiofield',
	   		 	    name : 'collectorGender',
	   		 	    label: 'Male',
	   		 	    value: 'Male',
	   		 	    checked: true
	   		 	},
	   		 	{
	   		 	    xtype: 'radiofield',
	   		 	    name : 'collectorGender',
	   		 	    label: 'Female',
	   		 	    value: 'Female'
	   		 	},
	   		 
	   		 ]
	   
	   	};
	   
	   	var noteFieldSet = {
	   		xtype: 'fieldset',
	   		id: 'collectorCommentFieldset',
	   		items: [
	   			{
	   			    xtype: 'textfield',
	   			    name : 'collectorComment',
	   			    label: 'Comments',
	   			    id: 'collectorCommentField'
	   			}
	   			
	   		
	   		]
	   	
	   	};
           
       
            

       	this.add([fieldSet, genderFieldSet, noteFieldSet]); 

    }

});